<div class="col-xs-10 col-xs-offset-1 form-horizontal mt20">
	<div class="panel ">
		<div class="panel-default text-center">
			<font face="Courier" class="" size="5">设备信息</font>
		</div>

		<div class="panel-body">
			<div class="form-group">
				<label class="col-xs-2 control-label">设备码</label>
				<div class="col-xs-6">
					<input type="text" class="form-control" ng-disabled="obj.type==7" placeholder="请输入设备码，该码作为设备的唯一标识，不能重复" ng-model="obj.code">
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">使用地点</label>
				<div class="col-xs-6">
					<!--<select class="form-control" ng-model="obj.view" ng-options="view.code as view.name for view in viewarr" ng-disabled="lock">
            </select>-->
					<ui-select ng-model="obj.view" theme="bootstrap" ng-disabled="lock">
						<ui-select-match placeholder="请选择一个地点">{{$select.selected.name}}</ui-select-match>
						<ui-select-choices repeat="item.code as item in viewarr | filter: $select.search">
							<span ng-bind-html="item.name | highlight: $select.search"></span>
							<span ng-show="item.code">({{item.code}})</span>
						</ui-select-choices>
					</ui-select>
				</div>
				<div class="col-xs-2">
					<button type="button" class="btn btn-primary " ng-click="remove()" ng-if="what == 'edit'">
				    	解除绑定
				    </button>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">密码</label>
				<div class="col-xs-6">
					<input type="text" class="form-control" ng-disabled="obj.type==7" placeholder="请输入密码" ng-model="obj.pas">
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">设备描述</label>
				<div class="col-xs-6">
					<input type="text" class="form-control" placeholder="请输入设备描述" ng-model="obj.remarks">
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">设备类型</label>
				<div class="col-xs-6">
					<select class="form-control" ng-model="obj.type" ng-disabled="updateFlag"
					ng-options="type.code as type.name for type in typearr"></select>
				</div>
			</div>


			<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
					<label class="col-xs-2 control-label">打印票长度</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="打印票长度" ng-model="obj.print_ticket_length">
					</div>
				</div>
	
				<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
					<label class="col-xs-2 control-label">打印票宽度</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="打印票宽度" ng-model="obj.print_ticket_width">
					</div>
				</div>
	
				<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
					<label class="col-xs-2 control-label">打印票X轴</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="打印票X轴" ng-model="obj.print_ticket_x_axis">
					</div>
				</div>
	
				<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
					<label class="col-xs-2 control-label">打印票y轴</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="打印票y轴" ng-model="obj.print_ticket_y_axis">
					</div>
				</div>
	
				<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
					<label class="col-xs-2 control-label">打印模板</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="打印模板" ng-model="obj.print_templete_code">
					</div>
				</div>


				<div class="form-group" ng-if="obj.type == 6">
						<label class="col-xs-2 control-label">图片</label>
						<div class="col-xs-6">
								<img ng-src="{{obj.img}}" width="100%" height="200" ng-model="obj.img">
								  <input type="file" nv-file-select uploader="uploader2" / ng-hide="hide===true" ><br/>
								  <ul class="list-group">
									<li class="list-group-item" ng-repeat="item in uploader2.queue">
									  文件名: <span ng-bind="item.file.name"></span>
									  <button type="button" class="btn btn-default btn-xs"  ng-click="item.upload()"><span class="glyphicon glyphicon-upload"></span> 上传</button>
									  <div class="progress mt10">
										<div class="progress-bar" role="progressbar" ng-style="{ 'width': uploader2.progress + '%' }"></div>
									  </div>
									</li>
								  </ul>
						   </div>
					</div>

				
			<div class="form-group" ng-if="obj.type == 5 || obj.type == 6">
				<label class="col-lg-2 control-label">打印模板</label>                       
                        <div class="col-lg-3">
                            <ui-select ng-model="obj.ticket_style_id" theme="bootstrap">
                                <ui-select-match placeholder="请选择一个模板">{{$select.selected.name}}</ui-select-match>
                                <ui-select-choices repeat="item.id as item in viewlist | filter: $select.search">
                                    <span>{{item.name}}</span>
                                </ui-select-choices>
                            </ui-select>
                		</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">设备状态</label>
				<div class="col-xs-3">
					<label class="radio-inline">
					  <input type="radio" name="state" ng-value="0"
					  ng-model="obj.state"
					  > 不可用
					</label>
					<label class="radio-inline">
					  <input type="radio" name="state" ng-value="1"
					  ng-model="obj.state"
					  > 可用
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">设备是否可用，请慎重选择</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">散票-权限状态</label>
				<div class="col-xs-3">
					<label class="radio-inline">
					  <input type="radio" name="auth_state" ng-value="0"
					  ng-model="obj.auth_state"
					  > 不启用
					</label>
					<label class="radio-inline">
					  <input type="radio" name="auth_state" ng-value="1"
					  ng-model="obj.auth_state"
					  > 启用
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">如果启用改选项，设备就必须配置票种，未配置的票种不能验证。</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">散票-销验票数量</label>
				<div class="col-xs-3">
					<label class="radio-inline">
					  <input type="radio" name="many_state" ng-value="0"
					  ng-model="obj.many_state"
					  > 单张
					</label>
					<label class="radio-inline">
					  <input type="radio" name="many_state" ng-value="1"
					  ng-model="obj.many_state"
					  > 多张
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">如果选择单张，每次只能消一张</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">团票-权限状态</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="group_auth_state" ng-value="0"
						ng-model="obj.group_auth_state"
						> 不启用
					</label>
					<label class="radio-inline">
						<input type="radio" name="group_auth_state" ng-value="1"
						ng-model="obj.group_auth_state"
						> 启用
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">团票验证权限</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">是否启用打印机</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="printer_open" ng-value="0"
						ng-model="obj.printer_open"
						> 不启用
					</label>
					<label class="radio-inline">
						<input type="radio" name="printer_open" ng-value="1"
						ng-model="obj.printer_open"
						> 启用
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">是否启用打印机</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">核销是否打印门票</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="verification_printing" ng-value="0"
						ng-model="obj.verification_printing"
						> 不打印
					</label>
					<label class="radio-inline">
						<input type="radio" name="verification_printing" ng-value="1"
						ng-model="obj.verification_printing"
						> 打印
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">核销是否打印门票</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">打印方式</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="printing_mode" ng-value="1"
						ng-model="obj.printing_mode"
						> 单张打印
					</label>
					<label class="radio-inline">
						<input type="radio" name="printing_mode" ng-value="2"
						ng-model="obj.printing_mode"
						> 合并打印 
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">打印方式</p>
				</div>
      </div>
      
      <div class="form-group">
				<label class="col-xs-2 control-label">设备营销统计和历史查询查询维度</label>
				<div class="col-xs-4">
					<label class="radio-inline">
						<input type="radio" name="inquiry_mode" ng-value="1"
						ng-model="obj.inquiry_mode"
						> 按照账号统计
					</label>
					<label class="radio-inline">
						<input type="radio" name="inquiry_mode" ng-value="2"
						ng-model="obj.inquiry_mode"
						> 按照设备号统计 
					</label>
				</div>
				<div class="col-xs-5">
					<p class="text-danger mt10">设备营销统计和历史查询查询维度</p>
				</div>
      </div>

      <div class="form-group">
				<label class="col-xs-2 control-label">支付方式</label>
				<div class="col-xs-6">
					<div class="col-sm-12 col-xs-12 mt5">
            <div class="row col-sm-3" ng-repeat="payobj in payarr">
                <label class="i-checks">
                    <input type="checkbox" name="rebate_type4" ng-model="payobj.value" value="{{payobj.value}}">
                    <i></i>
                    {{payobj.label}}
                </label>
            </div>
          </div>
				</div>
				<div class="col-xs-4">
					<p class="text-danger mt10">支付方式</p>
				</div>
      </div>
      <div class="form-group">
				<label class="col-xs-2 control-label">柜台编号</label>
				<div class="col-xs-6">
					<input type="text" class="form-control" placeholder="请输入柜台编号" ng-model="obj.counter_code">
				</div>
      </div>
      <div class="form-group">
				<label class="col-xs-2 control-label">旋转角度</label>
				<div class="col-xs-6">
					<input type="text" class="form-control" placeholder="请输入旋转角度（0 为不旋转）" ng-model="obj.rotation_angle">
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">售卖</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="sale_state" ng-value="0"
						ng-model="obj.sale_state"
						> 不启用
					</label>
					<label class="radio-inline">
						<input type="radio" name="sale_state" ng-value="1"
						ng-model="obj.sale_state"
						> 启用 
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">立式机设置</p>
				</div>
			  </div>
			  <div class="form-group">
				<label class="col-xs-2 control-label">核销</label>
				<div class="col-xs-3">
					<label class="radio-inline">
						<input type="radio" name="verifi_state" ng-value="0"
						ng-model="obj.verifi_state"
						> 不启用
					</label>
					<label class="radio-inline">
						<input type="radio" name="verifi_state" ng-value="1"
						ng-model="obj.verifi_state"
						> 启用 
					</label>
				</div>
				<div class="col-xs-7">
					<p class="text-danger mt10">立式机设置</p>
				</div>
      		</div>
      
      <!--<label class="checkbox-inline">
				<input type="checkbox" ng-model="strobj.checkstr1" ng-true-value="2"ng-false-value="" ng-click="checkcardinfo()">到店付
				</label>
				<label class="checkbox-inline">
				  <input type="checkbox" ng-model="strobj.checkstr2" ng-true-value="1"ng-false-value="" ng-click="checkcardinfo()">即时付
				</label>-->

			<!-- 闸机 -->
			<div ng-if="obj.type == 2">

				<div class="form-group">
					<label class="col-xs-2 control-label">打印后是否销票</label>
					<div class="col-xs-6">
						<label class="radio-inline">
						<input type="radio" name="print_destory_type" ng-value="'0'"
						ng-model="obj.print_destory_type"
						> 销票
					</label>
						<label class="radio-inline">
						<input type="radio" name="print_destory_type" ng-value="'1'"
						ng-model="obj.print_destory_type"
						> 不销票
					</label>
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10">针对是否有闸机景区</p>
					</div>
				</div>

			</div>
      <!-- 双屏pos -->
			<div ng-if="obj.type == 5">

				<div class="form-group">
					<label class="col-xs-2 control-label">绑定登录用户</label>
					<div class="col-xs-2">
						<input type="text" class="form-control" placeholder="请输入用户名" ng-model="obj.login_code">
          </div>
          <div class="col-xs-2">
						<input type="text" class="form-control" placeholder="请输入密码" ng-model="obj.pass_word">
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10">自助售票机，双屏pos机填写此项</p>
					</div>
        </div>
      </div>
			<!-- 双屏pos -->
			<div ng-if="obj.type == 6">

				<div class="form-group">
					<label class="col-xs-2 control-label">绑定登录用户</label>
					<div class="col-xs-2">
						<input type="text" class="form-control" placeholder="请输入用户名" ng-model="obj.login_code">
          </div>
          <div class="col-xs-2">
						<input type="text" class="form-control" placeholder="请输入密码" ng-model="obj.pass_word">
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10">自助售票机，双屏pos机填写此项</p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">域名设置</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="域名设置" ng-model="obj.netarea">
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">webssocket地址</label>
					<div class="col-xs-6">
						<input type="text" class="form-control" placeholder="webssocket地址" ng-model="obj.websocket">
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">是否启用刷卡</label>
					<div class="col-xs-6">
						<label class="radio-inline">
						<input type="radio" name="check_juyoucard_type" ng-value="'0'"
						ng-model="obj.check_juyoucard_type"
						> 启用
					</label>
						<label class="radio-inline">
						<input type="radio" name="check_juyoucard_type" ng-value="'1'"
						ng-model="obj.check_juyoucard_type"
						> 不启用
					</label>
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">是否启用刷身份证</label>
					<div class="col-xs-6">
						<label class="radio-inline">
						<input type="radio" name="check_personcard_type" ng-value="'0'"
						ng-model="obj.check_personcard_type"
						> 销票
					</label>
						<label class="radio-inline">
						<input type="radio" name="check_personcard_type" ng-value="'1'"
						ng-model="obj.check_personcard_type"
						> 不销票
					</label>
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">打印票类型</label>
					<div class="col-xs-6">
						<label class="radio-inline">
						<input type="radio" name="print_ticket_type" ng-value="'0'"
						ng-model="obj.print_ticket_type"
						> 销票
					</label>
						<label class="radio-inline">
						<input type="radio" name="print_ticket_type" ng-value="'1'"
						ng-model="obj.print_ticket_type"
						> 景区定制门票
					</label>
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>

				<div class="form-group">
					<label class="col-xs-2 control-label">票码类型</label>
					<div class="col-xs-6">
						<label class="radio-inline">
						<input type="radio" name="ticket_code_type" ng-value="'0'"
						ng-model="obj.ticket_code_type"
						> 一单一码
					</label>
						<label class="radio-inline">
						<input type="radio" name="ticket_code_type" ng-value="'1'"
						ng-model="obj.ticket_code_type"
						> 一单多码
					</label>
					</div>
					<div class="col-xs-4">
						<p class="text-danger mt10"></p>
					</div>
				</div>
			</div>

			<!--<div class="form-group">
				<label class="col-xs-2 control-label">创建时间</label>
				<div class="col-xs-6">
					<p class="form-control-static">{{obj.create_time}}</p>
				</div>
			</div>

			<div class="form-group">
				<label class="col-xs-2 control-label">修改时间</label>
				<div class="col-xs-6">
					<p class="form-control-static">{{obj.update_time}}</p>
				</div>
			</div>-->

			<button type="button" class="btn btn-primary btn-lg btn-block" ng-click="gogo()">
    提交
    </button>
		</div>
	</div>

</div>